package com.gtw.interpreter;

import java.util.HashMap;

/**
 * 通常终结符表达式比较简单,主要处理场景元素和数据的转换
 */
public class TerminalExpression extends Expression {
    private String key;

    public TerminalExpression(String key) {
        this.key = key;
    }

    public int interpret(HashMap<String, Integer> var) {
        return var.get(this.key);
    }
}
